<!-- Code Field -->
<div class="form-group">
    {!! Form::label('code', '题号：') !!}
    <p>{!! $questions->code !!}</p>
</div>

<!-- Content Field -->
<div class="form-group">
    {!! Form::label('content', '问题：') !!}
    <p>{!! $questions->content !!}</p>
</div>

<!-- Next Id Field -->
<div class="form-group">
    {!! Form::label('next_id', '下一题：') !!}
    <p>{!! $questions->nextQuestion ? $questions->nextQuestion->code : '暂无' !!}</p>
</div>

<!-- Temp Id Field -->
<div class="form-group">
    {!! Form::label('temp_id', '所属问卷：') !!}
    <p>{!! $questions->temp->name !!}</p>
</div>

<!-- Type Field -->
<div class="form-group">
    {!! Form::label('type', '题型：') !!}
    <p>{!! $type[$questions->type] !!}</p>
</div>

@if($questions->type === 1)
    <div class="form-group">
        {!! Form::label('option', '选项：') !!}
        @foreach($questions->options as $v)
            <p>{!! $v['code'] !!}. {!! $v['content'] !!}</p>
        @endforeach
    </div>
    @elseif($questions->type === 2)
    <div class="form-group">
        {!! Form::label('option', '选项：') !!}
        @foreach($questions->options as $k => $v)
            <p>{!! $k + 1 !!}. {!! $v['content'] !!}</p>
        @endforeach
    </div>
@endif

